home *** CD-ROM | disk | FTP | other *** search
/ TeX 1995 July / TeX CD-ROM July 1995 (Disc 1)(Walnut Creek)(1995).ISO / macros / text1 / cms_help_files / settabs.helpmark < prev    next >
Text File  |  1991-10-23  |  8KB  |  152 lines

  1. +-----------------------------------------------------------------------------+
  2. |                                   settabs                                   |
  3. +-----------------------------------------------------------------------------+
  4.  
  5. Abbreviation:  π|noneπ%
  6.  
  7. Parameters:    π|number of columnsπ%
  8.  
  9.     π|Description:π%
  10. The body of the table is  created with the \settabs n \columns markup, which
  11. establishes a number (n) of equal-size tabular columns (\columns).
  12.     Each  new  column  after the  first  is  indicated  with  the TEXT1  tab
  13. character (&).   Each row is  started with the \+ markup  and ended with the
  14. \cr markup (which is an abbreviation for carriage return on typewriters).
  15.     The ampersand  (&) is  like the  TAB key on  many typewriters;  it tells
  16. TEXT1 to advance to the next tab position, where there is a tab at the right
  17. edge of  each column.   But  & is not  exactly like  a mechanical typewriter
  18. TAB,  because it  first backs  up  to the  beginning of  the  current column
  19. before advancing to the  next.  In this way  you can always tell what column
  20. you are  tabbing to, by  counting the number  of &s; that  is handy, because
  21.  
  22. variable-width type  otherwise makes it  difficult to know  whether you have
  23. passed a tab position.
  24.     The  ampersands are  different from  tabs in  another way,  too:   TEXT1
  25. ignores spaces after &, hence you can conveniently finish a column by typing
  26. & at the  end of a line  in your input file, without  worrying that an extra
  27. blank space  will be  introduced there.    Incidentally, TEXT1  also ignores
  28. spaces after \+, so that the first column is treated like the others.
  29.     You can say \cr before you  have specified a complete set of columns, if
  30. the remaining columns are  blank.  The last \cr ends  the settabs.  No other
  31. ending is necessary; normal text may follow.
  32.  
  33.     π|Example:π%
  34.  
  35. can be seen, the pool of common words is prodigious.
  36. \par
  37. \tabletitle{Etymological Clues}
  38. \settabs 3 \columns
  39. \+\it Term&\it Geological&\it Social Reference\cr
  40. \+boss&small rock&supervisor\cr
  41. \+domehead&pushing through&intellectual\cr
  42. \+fossil&turned to stone&age\cr
  43. \+creep&move slowly&person\cr
  44. \+streak&move quickly&naked\cr
  45. \+ejecta&very quickly&mating\cr
  46. \+sublimate&change to gas&dream\cr
  47. \+trench&sediments&mouth\cr
  48.  
  49. +-----------------------------------------------------------------------------+
  50. |                                                                             |
  51. |  can be seen, the pool of common words is prodigious.                       |
  52. |                                                                             |
  53. |                                  Table 1                                    |
  54. |                            Etymological Clues                               |
  55. |                                                                             |
  56. | Term                     Geological                 Social Reference        |
  57. | boss                     small rock                 supervisor              |
  58. | domehead                 pushing through            intellectual            |
  59. | fossil                   turned to stone            age                     |
  60. | creep                    move slowly                person                  |
  61. | streak                   move quickly               naked                   |
  62. | ejecta                   very quickly               mating                  |
  63. | sublimate                change to gas              dream                   |
  64. | trench                   sediments                  mouth                   |
  65. |                                                                             |
  66. +-----------------------------------------------------------------------------+
  67.  
  68.     π|Example:π%
  69. You may not want all of the columns to be the same size, so there is another
  70. way to  set them, by  typing "\+sample line\cr"  immediately after \settabs.
  71. In this case tabs are placed  at the positions of the &s in the sample line,
  72. but the  sample line  itself does not  appear in the  output.   Look through
  73. the table  and determine the biggest  entry in each column;  the sample line
  74. is then  constructed by typing  the widest entry  in the first  column, then
  75. the widest in each subsequent column,  omitting the last column.  Be sure to
  76. include some extra space  (\horizontalspace{}) between columns in the sample
  77. line, so that the columns won't touch each other.
  78.  
  79. can be seen, the pool of common words is prodigious.
  80. \par
  81. \tabletitle{Etymological Clues}
  82. \settabs\+\hs{4pt}&domeheads\hs{4pt}
  83.   &material pushing through
  84.   \hs{10pt}&Intellectual\cr
  85. \+&\it Term&\it Geological&\it Social Reference\cr
  86. \+&trench&subducted sediments&mouth\cr
  87.  
  88. \+&dike&material holding back&female\cr
  89. \+&domehead&material pushing through&intellectual\cr
  90. \+&fossil&life turned to stone&age\cr
  91. \+&cleavage&the tendency to split&bosom\cr
  92.  
  93. +-----------------------------------------------------------------------------+
  94. |                                                                             |
  95. |  can be seen, the pool of common words is prodigious.                       |
  96. |                                                                             |
  97. |                                  Table 2                                    |
  98. |                            Etymological Clues                               |
  99. |                                                                             |
  100. | Term      Geological                Social Reference                        |
  101. | trench    subducted sediments       mouth                                   |
  102. | dike      material holding back     female                                  |
  103. | domehead  material pushing through  intellectual                            |
  104. | fossil    life turned to stone      age                                     |
  105. | cleavage  the tendency to split     bosom                                   |
  106. |                                                                             |
  107. +-----------------------------------------------------------------------------+
  108.  
  109.     π|Example:π%
  110. If you  want to put something  right justified (flush right)  in its column,
  111. just type \rt{text}  where text is the  text to be right  justified; Be sure
  112. to type  & after it, so  that TEX will  be sure to move  the information all
  113. the way  until it touches the  next tab.   Similarly, if you  want to center
  114. something  in its  column,  type \ctr{text}  where text  is  the text  to be
  115. centered.  Notice also the use of \phantom in decimal alignment.
  116.  
  117.    \centerline{\bd Table 1}
  118.    \centerline{Etymological Clues}
  119.    \settabs \+\hs{20pts}&Aluminum\quad&Anthrosphere&
  120.                \hs{20pt}&Lithosphere\quad\cr
  121.    \+&\lft{Element}&\rt{Anthrosphere}&
  122.                       &\rt{Lithosphere}&\cr
  123.    \+&Sodium&\rt{0.001\phantom{0}}&&\rt{0.4\phantom{000}}\cr
  124.    \+&Silicon&\rt{.0001}&&\rt{20.2\phantom{000}}\cr
  125.    \+&Aluminum&\rt{0.22\phantom{00}}&&
  126.          \rt{11.54\phantom{00}}\cr
  127.    \+&Carbon&\rt{19.1001}&&\rt{0.0202}\cr
  128.  
  129.    \+&Nitrogen&\rt{3.2205}&&\rt{.0208}\cr
  130.  
  131. +-----------------------------------------------------------------------------+
  132. |                                                                             |
  133. |                                  Table 1                                    |
  134. |                            Etymological Clues                               |
  135. |   Element  Anthrosphere  Lithosphere                                        |
  136. |   Sodium         0.001   0.4                                                |
  137. |   Silicon         .0001  20.2                                               |
  138. |   Aluminum       0.22    11.54                                              |
  139. |   Carbon        19.1001  0.0202                                             |
  140. |   Nitrogen       3.2205  .0208                                              |
  141. |                                                                             |
  142. +-----------------------------------------------------------------------------+
  143.  
  144.     π|Notes:π%
  145.  
  146. Tab positions  are remembered, until  they are reset  with another \settabs,
  147. regardless of text and other markup following.
  148.     The operation of tabs addresses one line at a time; this allows multiple
  149. page tables.
  150.     You cannot use \figure, \drawbox or \paragraphbox around a \settabs.
  151.     Refer to The TEXbook for more on \phantom.
  152.